package logging

import (
	"fmt"
	"time"

	"github.com/EDDYCJY/go-gin-example/pkg/setting"
)

// getLogFilePath get the log file save path
func getLogFilePath() string {
	return fmt.Sprintf("%s%s", setting.AppSetting.RuntimeRootPath, setting.AppSetting.LogSavePath) //运行数据保存的目录名称，日志保存目录
}

// getLogFileName get the save name of the log file
func getLogFileName() string {
	return fmt.Sprintf("%s%s.%s",
		setting.AppSetting.LogSaveName,	//配置文件中为log
		time.Now().Format(setting.AppSetting.TimeFormat),	//当前的日期，格式为为20210916
		setting.AppSetting.LogFileExt,	//配置文件中日志的后缀名，为log
	)
}
